﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;
using System.ServiceModel.Web;
using RESTServices.Dominio;
namespace RESTServices
{
    // NOTA: puede usar el comando "Rename" del menú "Refactorizar" para cambiar el nombre de interfaz "IReservas" en el código y en el archivo de configuración a la vez.
    [ServiceContract]
    public interface IReservas
    {

        [OperationContract]
        [WebInvoke(Method = "POST", UriTemplate = "Reservas/CrearRes", ResponseFormat = WebMessageFormat.Json)]
        ReservaAdic CrearRes(Reserva resAcrear);

        [OperationContract]
        [WebInvoke(Method = "GET", UriTemplate = "Reservas/ObtenerRes/{codigo}", ResponseFormat = WebMessageFormat.Json)]
        ReservaAdic ObtenerRes(string codigo);

        [OperationContract]
        [WebInvoke(Method = "GET", UriTemplate = "Reservas/Listar/{codigo}", ResponseFormat = WebMessageFormat.Json)]
        List<Reserva> Listar(string codigo);


        [OperationContract]
        [WebInvoke(Method = "GET", UriTemplate = "Reservas/ListarReservas/{codigo}", ResponseFormat = WebMessageFormat.Json)]
        List<ReservaAdic> ListarReservas(string codigo);

        [OperationContract]
        [WebInvoke(Method = "DELETE", UriTemplate = "Reservas", ResponseFormat = WebMessageFormat.Json)]
        void EliminarReserva(string codigo);

        [OperationContract]
        [WebInvoke(Method = "PUT", UriTemplate = "Reservas", ResponseFormat = WebMessageFormat.Json)]
        ReservaAdic ModificarReserva(Reserva reservaAModificar);

        [WebInvoke(Method = "GET", UriTemplate = "Reservas/Mensaje", ResponseFormat = WebMessageFormat.Json)]
        [OperationContract]
        Reserva RecibirReserva();

        [WebInvoke(Method = "POST", UriTemplate = "Reservas/Enviar", ResponseFormat = WebMessageFormat.Json)]
        [OperationContract]
        void EnviarReserva(Reserva reservaAnotarse);
 
    }
}
